package com.fangyi.yunmusic.service;

import com.fangyi.yunmusic.pojo.User;
import com.fangyi.yunmusic.pojo.detail.UserDetail;
import com.fangyi.yunmusic.pojo.vo.UserVO;

public interface UserService {

    /**
     * 通过用户ID获取用户
     * @param userId
     * @return
     */
    public User selectUserById(String userId);
    public void deleteUserById(String userId);
    public void addUser(User user);
    public void updateUser(User user);

    public boolean userRegister(String nickname,String password,String description);//注册

    public String userLogin(String nickName,String password);//登录(成功即返回userId)

    public boolean updatePassword(String userId,String oldPassword,String newPassword);//修改密码

    public boolean updateDescription(String userId,String description);//修改个人简介

    public UserDetail getUserMessage(String userId);//获取用户信息

    public boolean verifyUsernameRepetition(String userName);//验证用户名是否重复

    public UserVO queryUserForLogin(String nickname, String password) throws Exception;  // 查询登录信息是否正确，返回用户信息

    public Boolean checkUserIsArtist(String userId);
}
